//
//  HYCTourPalModel.m
//  FamilyTravel
//
//  Created by dllo on 15/10/29.
//  Copyright (c) 2015年 蓝鸥科技. All rights reserved.
//

#import "HYCTourPalModel.h"

@implementation HYCTourPalModel
- (void)dealloc
{
    [_created_by release];
    [_created_date release];
    [_last_modified_date release];
    [_name release];
    [_trail_id release];
    [_cover release];
    [_photo_number release];
    [_start_date release];
    [_end_date release];
    [_destination release];
    [_fav_count release];
    [_total_days release];
    [_is_sticky release];
    [_number release];
    
    [super dealloc];
}

- (void)setValue:(id)value forUndefinedKey:(NSString *)key {
    if ([key isEqualToString:@"id"]) {
         self.number = value;
    }
}

- (void)encodeWithCoder:(NSCoder *)aCoder {
    
    [aCoder encodeObject:self.number forKey:@"number"];
    [aCoder encodeObject:self.is_sticky forKey:@"is_sticky"];
    [aCoder encodeObject:self.total_days forKey:@"total_days"];
    [aCoder encodeObject:self.fav_count forKey:@"fav_count"];
    [aCoder encodeObject:self.name forKey:@"name"];
    
}
-(id)initWithCoder:(NSCoder *)aDecoder{
    self = [super init];
    if (self) {
        self.number = [aDecoder decodeObjectForKey:@"number"];
        self.is_sticky = [aDecoder decodeObjectForKey:@"is_sticky"];
        self.total_days = [aDecoder decodeObjectForKey:@"total_days"];
        self.fav_count = [aDecoder decodeObjectForKey:@"fav_count"];
        self.name = [aDecoder decodeObjectForKey:@"name"];
    }
    return self;
}

@end
